Disable "ostree trivial-httpd" by default now
authorColin Walters <walters@verbum.org>
Tue, 7 Mar 2017 22:32:50 +0000 (17:32 -0500)
committerAtomic Bot <atomic-devel@projectatomic.io>
Mon, 13 Mar 2017 14:07:18 +0000 (14:07 +0000)
This goes farther along the path of deprecating it; consumers should
have been ported at this point.  Though probably a lot of people
may still use `rpm-ostree-toolbox`.

Closes: #723
Approved by: jlebon

configure.ac
src/ostree/main.c

index 64f1fa4b51c3b09e7083cb1a2aa8c9cc55f27e6e..be1e0e13146c7afaabe0e2445482e978863f09d6 100644 (file)
@@ -143,6 +143,14 @@ if test x$with_soup != xno; then OSTREE_FEATURES="$OSTREE_FEATURES libsoup"; fi
 AM_CONDITIONAL(USE_LIBSOUP, test x$with_soup != xno)
 AM_CONDITIONAL(HAVE_LIBSOUP_CLIENT_CERTS, test x$have_libsoup_client_certs = xyes)
 
+AC_ARG_ENABLE(trivial-httpd-cmdline,
+  [AS_HELP_STRING([--enable-trivial-httpd-cmdline],
+  [Continue to support "ostree trivial-httpd" [default=no]])],,
+  enable_trivial_httpd_cmdline=no)
+AS_IF([test x$enable_trivial_httpd_cmdline = xyes],
+  [AC_DEFINE([BUILDOPT_ENABLE_TRIVIAL_HTTPD_CMDLINE], 1, [Define if we are enabling ostree trivial-httpd entrypoint])]
+)
+
 AS_IF([test x$with_curl = xyes && test x$with_soup = xno], [
   AC_MSG_ERROR([Curl enabled, but libsoup is not; libsoup is needed for tests])
 ])
@@ -420,6 +428,7 @@ echo "
     Rust (internal oxidation):                    $rust_debug_release
     rofiles-fuse:                                 $enable_rofiles_fuse
     HTTP backend:                                 $fetcher_backend
+    \"ostree trivial-httpd\":                       $enable_trivial_httpd_cmdline
     SELinux:                                      $with_selinux
     systemd:                                      $have_libsystemd
     libmount:                                     $with_libmount
index eff3082dcdda244a6f494b735d27a4629770c38f..c6dee4eecb791493c032d9040863203459630fc0 100644 (file)
@@ -58,7 +58,7 @@ static OstreeCommand commands[] = {
   { "show", ostree_builtin_show },
   { "static-delta", ostree_builtin_static_delta },
   { "summary", ostree_builtin_summary },
-#ifdef HAVE_LIBSOUP 
+#if defined(HAVE_LIBSOUP) && defined(BUILDOPT_ENABLE_TRIVIAL_HTTPD_CMDLINE)
   { "trivial-httpd", ostree_builtin_trivial_httpd },
 #endif
   { NULL }